<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<div id="contentmid">
    <s:if test="#session.loggedUser != null && #session.loggedUser.username == utente.username">
    <div class="midheading">
        <h2>Le tue inserzioni</h2>
    </div>
    <div class="midtxt">Pubblica una <a href="<s:url action='nuova_inserzione'/>">nuova inserzione</a><br><br></div>
    <div class="midheading">
        <h2>Elenco inserzioni</h2>
    </div>
    <div class="midtxt">
    <table>
    <s:iterator value="inserzioniUtente">
        <tr>
                <td><s:property value="nome"/></td>
                
                <td>
                       <s:form action="dettaglio_articolo">
                           <s:hidden name="idArticolo" value="%{idArticolo}"/>
                           <s:submit type="image" src="img/catalogo/get-info-b.png"/>
                       </s:form>
                    </td>
                
                 </tr>
    </s:iterator>  
    </table>  
    <form>
        <input type="button" value="Indietro" onClick="javascript:history.back()" name="button">
    </form>
    </div>
    </s:if>
    <s:else>
        <h3><s:text name="message.notlogged"/></h3>
    </s:else>
</div>